﻿@*@model IEnumerable<FinalProject.Entities.Client>*@
@model List<FinalProject.Web.ViewModels.ClientViewModel>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table>
    <tr>
        <th>
            FirstName
        </th>
        <th>
            LastName
        </th>
        <th>
            Middle Name
        </th>
      @*  <th>
            Phone
        </th>
        <th>
            LastEdited
        </th>
        <th>
            LastAccessed
        </th>
        <th>
            StoreId
        </th>
        <th></th>*@
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.PersonName.FirstName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.PersonName.LastName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.PersonName.MiddleName)
        </td>
        @*<td>
            @Html.DisplayFor(modelItem => item.Phone)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.LastEdited)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.LastAccessed)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.StoreId)
        </td>*@
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.Id }) |
            @Html.ActionLink("Details", "Details", new { id=item.Id }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.Id })
        </td>
    </tr>
}

</table>
